<template>
  <div>
    <div style="height: 60px"></div>
    <div class="foot" :style="`width:${width - 180}px`">
      <slot></slot>
    </div>
  </div>
</template>

<script>
export default {
  mounted() {
    this.width = document.documentElement.clientWidth;
    window.onresize = () => {
      return (() => {
        this.width = document.documentElement.clientWidth;
      })();
    };
  },
  data() {
    return {
      width: document.documentElement.clientWidth,
    };
  },
};
</script>

<style scoped>
.foot {
  width: 100%;
  height: 60px;
  position: absolute;
  right: 0;
  bottom: 0;
  background: #fff;
  box-shadow: 0px 0px 4px 0px rgba(0, 0, 0, 0.1);
  border-left: 1px solid #fefefe;
  display: flex;
  flex-direction: row;
  justify-content: center;
  align-items: center;
}
</style>